#!/bin/sh

exec java -server ${JAVA_OPTS} \
  -jar \
  -Duser.timezone=Asia/Shanghai \
  -Djava.security.egd=file:/dev/./urandom \
  -Dconsole.default.user-name=${CONSOLE_USERNAME} \
  -Dconsole.default.password=${CONSOLE_PASSWORD} \
  -Dantrpc.zookeeper=${ZOOKEEPER_HOSTS} \
  -Dantrpc.elasticsearch.hosts=${ES_HOSTS} \
  -Dantrpc.elasticsearch.username=${ES_USERNAME} \
  -Dantrpc.elasticsearch.password=${ES_PASSWORD} \
  -Dspring.datasource.url=${MYSQL_URL} \
  -Dspring.datasource.username=${MYSQL_USERNAME} \
  -Dspring.datasource.password=${MYSQL_PASSWORD} \
  "${HOME}/app.war" "$@"
